package com.youpai.platform.pay.service.service;

import com.google.api.services.androidpublisher.model.ProductPurchase;
import com.youpai.platform.pay.web.entity.dto.GooglePayDTO;
import com.youpai.platform.pay.web.entity.resp.CheckGooglePayResp;

import java.io.IOException;
import java.security.GeneralSecurityException;

/**
 * @date: 2022/12/25
 * @author: Welles
 * @version: 1.0
 * @description: google支付回调service
 */
public interface GooglePayCallBackService {

    /**
     * 校验订单
     *
     * @param googlePayDTO google支付dto
     * @return 校验结果
     */
    CheckGooglePayResp checkGooglePay(GooglePayDTO googlePayDTO);

    /**
     * 退款
     *
     * @param appId   appId
     * @param orderId 订单id
     * @return 退款结果
     */
    boolean refundOrder(int appId, String orderId);
}
